package testPage;

import common.RegisterUser;
import org.junit.jupiter.api.Test;
import page.RegisterPage;

import static org.junit.jupiter.api.Assertions.*;

class RegisterPageTest {

    RegisterPage registerPage = new RegisterPage();
    @Test
    void openRegisterPage() throws InterruptedException {
        registerPage.openRegisterPage();
        registerPage.close();
    }

    @Test
    void register() throws InterruptedException {
        //成功
        RegisterUser user = new RegisterUser("9990","9990","9990","9990");
        registerPage.register(user);
        //失败
        RegisterUser user1 = new RegisterUser("","99","99","99");
        registerPage.register(user1);
        registerPage.close();
    }
}